package com.qfedu.microlottery.award.controller;

import com.qfedu.common.core.common.R;
import com.qfedu.microlottery.award.service.LotteryawardService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Classname LotteryawardController
 * @Description TODO
 * @Date 2025-10-09 14:31
 * @Created by 老任与码
 */
@RestController
@RequestMapping("/api/lottery/award")
public class LotteryawardController {

    @Resource
    private LotteryawardService lotteryawardService;

    /**
     * 抽奖接口
     *
     * @param activityId
     * @return
     */
    @GetMapping
    public R lottery(Integer activityId) {
        int lottery = lotteryawardService.lottery(activityId);
        return R.success(lottery);
    }

}
